package sc.test.spring.rest;

import java.util.Date;
import java.util.Random;

import javax.ws.rs.Consumes;
import javax.ws.rs.GET;
import javax.ws.rs.Path;
import javax.ws.rs.Produces;

@Path("/")
public class RestService {

    @GET
    @Path("getRestResponse")
    @Produces("application/json")
    public RestResponse getRestResponse() {
        RestResponse resp = new RestResponse();
        resp.id = "ABC";
        resp.number = new Random(new Date().getTime()).nextInt(100);
        System.out.println(resp);
        return resp;
    }

}
